﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MINERP.BLL.PrintManage
{
    public class IMETTO
    {
        private const int BUFFERSIZE = 6000;
        private const int PACKSIZE = 0x10000;

        private enum CommandList
        {
            READIMAGE = 0X01,
            SHUTDOWN = 0X02,
            REBOOT = 0X03,
            LOCK = 0X04,
            UNLOCK = 0X05,
            REFLAG = 0X06,
            ASKIMAGELIST = 0X07,
            REIMAGELIST = 0x08,
            CLOSE = 0X09,
            EXECUTE = 0X11,
            LOADFILE = 0X12,
            CLOSESPY = 0X13,
            CANCELALL = 0x14,
            UPDATECOLOR = 0x15,
            QUEUEOVER = 0x16,
            EXPOSUREWAITING = 0x17,
            MMUSEDOVER = 0x18,
            NETCLOSE = 0x19,
            UPDATETIDADENS = 0x1A,
            NETREFUSE = 0x1B,
            CLRCALCUFINISHED = 0x1C,
            PAPERCHANNEL = 0x1D,
            PAPERCHANNELCLOSE = 0x1E,
            SERVERPAPERNAME = 0x1F,
            RECEIVEFILE = 0x20,
            RECEIVEREADY = 0x21,
            CALCUCLR = 0x22,
            PAPERCHANNEL_RESSEND = 0x23,
            PAPERCHANNEL_RESRECIEVE = 0x24
        }

        public  struct PrinterInfo
        {
	        string  ImageName; //print file name，Not NULL,max 20
	        int   PaperType;　//Paper type，reserve
	        int   CopyNumber; //Print copy
	        ushort  Command; //Network command
	        uint Size; //The size of the print task image, bytes size
	        uint Height; //Image Height
	        uint Width; //Image Width
	        DateTime Time; //Print time, reserve
        }

        public struct IMAGELIST
        {
	        string  ImageName; //char ImageName[20]
	        int   CopyNumber;
	        int   Sequence;        
	        DateTime Time;
        }

        public struct CMMD
        {
	        uint Command;
	        uint Size;
        }

        public struct ImettoStruct
        {
            uint Size;
            uint Height;
            uint Width;
            UInt16[] P;	        //LPBYTE P;
	        byte Erro;
        }
    }
}
